package com.indusfo.spc.mapper;

import com.indusfo.spc.pojo.BatchDete;
import com.indusfo.spc.pojo.BatchDete;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @Author liub
 * @Date 2019/12/5 15:05
 * @Version 1.0
 */

public interface BatchDeteMapper {
    /**
     * 新增
     */
    int insertBatchDete(BatchDete batchDete);

    /**
     * 修改
     */
    int updateBatchDete(BatchDete batchDete);

    /**
     * 查询
     */
    List<BatchDete> queryBatchDete(BatchDete batchDete);

    /**
     * 总数
     */
    int countBatchDete(BatchDete batchDete);

    /**
     * 判重
     */
    int checkBatchDete(BatchDete batchDete);

    /**
     * 启停
     */
    int deleteBatchDete(@Param("batchDeteIds") List<Integer> batchDeteIds, @Param("dataState") Integer dataState);

    /**
     * 级联删除查询
     */
    List<BatchDete> queryBatchDeteByBatchFlowId(@Param("batchFlowId") Integer batchFlowId);

    /**
     * 级联删除
     */
    int deleteBatchDeteByBatchDeteId(@Param("batchDeteId") Integer batchDeteId, @Param("dataState") Integer dataState);
}